tools/hotplug/Linux: re-factor add_to_bridge() in xen-network-common.sh
authorPaul Durrant <pdurrant@amazon.com>
Tue, 11 Aug 2020 08:01:56 +0000 (09:01 +0100)
committerWei Liu <wl@xen.org>
Thu, 27 Aug 2020 10:04:04 +0000 (10:04 +0000)
commit70fea87a3a595632cd0a17a8388a43b95cbe7af7
tree3a05238e9c4ab409a5265ca92f231eecf2f0ffd0
parentf9d25fa3faf66bcd4265fe01f23c5fd724e27601
tools/hotplug/Linux: re-factor add_to_bridge() in xen-network-common.sh

Remove duplication of 'ip link set dev'. It is perfectly fine to call it
even if the device has already been added to the bridge.

NOTE: This patch also adds code to write a debug log entry if the device
      was already on the bridge.

Signed-off-by: Paul Durrant <pdurrant@amazon.com>
Acked-by: Wei Liu <wl@xen.org>
tools/hotplug/Linux/xen-network-common.sh